#ifndef MAINWINDOW_H
#define MAINWINDOW_H

#include <QMainWindow>
#include <QHBoxLayout>
#include <QAction>
#include <QMenuBar>
#include <QMouseEvent>
#include "TCPGameManager.h"
#include "GLConnectFour.h"
#include "SideWidget.h"
#include "GuiParameters.h"

#include <QDebug>

class MainWindow : public QMainWindow {

    Q_OBJECT

public:
    explicit MainWindow(QWidget *parent = 0);

signals:
    void quit();

public slots:

private slots:
     void newGame();
     void requestNewGame();
     void undo();
     void newGameManager(Network::ConnectionStatus status, QTcpSocket * socket);

protected:
     void mousePressEvent(QMouseEvent *event);
     void keyPressEvent(QKeyEvent * event);

private:
     void connectSignalSlots();
     void connectGameSignalSlots();
     void createActions();
     void createMenus();

     GameManager * gameManager;
     QWidget * mainWidget;
     GLConnectFour * glConnectFour;
     SideWidget * sideWidget;
     ChatWidget const * chatWidget;
     QMenu * gameMenu;
     QAction * newGameAction;
     QAction * undoAction;
};

#endif // MAINWINDOW_H
